home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 4814 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  863 b 

  1. Path: news.widomaker.com!sgross
  2. From: sgross@widomaker.com (Stephen Gross)
  3. Newsgroups: comp.lang.c
  4. Subject: question on borland c++ 3.1
  5. Date: 7 Feb 1996 05:07:04 GMT
  6. Organization: Widomaker Public Access Internet (804)221-8070
  7. Message-ID: <4f9c1o$aem@news2.widomaker.com>
  8. NNTP-Posting-Host: wilma.widomaker.com
  9. X-Newsreader: TIN [version 1.2 PL2]
  10.  
  11. I've been using bc 3.1 for a while now, and i was wondering if anyone can 
  12. tell me: is this a bug with the compiler? The following code:
  13.  
  14. void flip()
  15. {
  16.   asm {
  17.     cld
  18.     lds si,[dword ptr V_PAGE]
  19.     mov ax,0xa000
  20.     mov es,ax
  21.     mov di,0
  22.     mov cx,32000
  23.     rep movsw
  24.     lds si,[dword ptr V_PAGE]
  25.     mov ax,0
  26.     mov cx,32000
  27.     rep stosw
  28.     }
  29. {
  30.  
  31. it does not work, in that V_PAGE gets set to 0, right after the "rep 
  32. movsw". Is the problem something stupid in my code, or in the compiler?
  33.  
  34. thanx, sgross
  35.  
  36.